import {secklist} from '../../../request/api'
const state = {
    seckList:[]
}
const getters = {
    getSeckList(state){
        return state.seckList
    }
}
const mutations = {
    REQ_SECKLIST(state,payload){
        state.seckList = payload
    }
}
const actions = {
    changeSeckAction({commit}){
        secklist().then((res)=>{
            if(res.data.code==200){
                let list = res.data.list?res.data.list:[]
                commit('REQ_SECKLIST',list)
            }
        })
    }
}
export default {
    state,
    getters,
    mutations,
    actions,
    // 开启命名空间
    namespaced:true,
}